﻿using GalaSoft.MvvmLight;
using MedicineTracker.Model;
using System.Windows.Input;
using System.Windows;
using GalaSoft.MvvmLight.Command;
using System.Data;
using System.Collections.ObjectModel;

namespace MedicineTracker.ViewModel
{
    /// <summary>
    /// This class contains properties that the main View can data bind to.
    /// <para>
    /// Use the <strong>mvvminpc</strong> snippet to add bindable properties to this ViewModel.
    /// </para>
    /// <para>
    /// See http://www.galasoft.ch/mvvm/getstarted
    /// </para>
    /// </summary>
    public class MainViewModel : ViewModelBase
    {
        private readonly RelayCommand _exit;

        public RelayCommand ExitCommand { get { return _exit; } }

        /// <summary>
        /// Initializes a new instance of the MainViewModel class.
        /// </summary>
        public MainViewModel()
        {
            _exit = new RelayCommand(
                () => Application.Current.Shutdown(),
                () => true
                );
        }

        public override void Cleanup()
        {
            base.Cleanup();
        }
    }
}